/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: lenovo
 * Date: 2022-12-16
 * Time: 21:14
 */
public class Test {
    private static void fun(int a) throws MyException{
        if (a == 10){
            throw  new MyException("哈哈!自定义异常有意思");
        }
    }
    public static void main(String[] args) {
        try {
            fun(10);
        } catch (MyException e) {
            e.printStackTrace();
        } finally {
            System.out.println("sjkgdsdg");

        }

    }
}
